const TopClient = require("./lib/api/topClient.js").TopClient;
const client = new TopClient({
  appkey: "28876583",
  appsecret: "DHxcbhi2euoO0zJSn9VrMztASAJDHxcHxcbhi2euoO0",
  url: "https://eco.woyueche.com/router/rest",
});

client.execute('taobao.top.auth.token.create', {
  'code':'aHN2dSSbqO7it7Xu7O9M8ECA5281674',
 }, function(error, response) {
  if (!error) console.log(response);
  else console.log(error);
})

// client.execute(
//   "taobao.trades.sold.increment.get",
//   {
//     fields: "tid,type,status,payment,orders,rx_audit_status",
//     start_modified: "2000-01-01 00:00:00",
//     end_modified: "2000-01-02 00:00:00",
//     status: "TRADE_NO_CREATE_PAY",
//     type: "fixed",
//     buyer_nick: "zhangsan",
//     ext_type: "service",
//     tag: "time_card",
//     page_no: "1",
//     rate_status: "RATE_UNBUYER",
//     page_size: "40",
//     use_has_next: "true",
//     buyer_open_uid: "AAHm5d-EAAeGwJedwSHpg8bT",
//   },
//   function (error, response) {
//     if (!error) console.log(response);
//     else console.log(error);
//   }
// );

// http://127.0.0.1/?code=hfUdyeOeK1jjywM6KHJLJDjt9056816
